<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
    <th:block th:include="include :: header('查看有权人签字列表')" />
</head>
<body class="gray-bg">
     <div class="container-div">
        <div class="row">
            <form id="formId">
                <div class="select-list">
                    <input type="hidden" name="orgCode" th:value="${paeaParaAuthorizedSignature.orgCode}"/>
                </div>
            </form>
            <div class="col-sm-12 select-table table-striped">
                <table id="bootstrap-table"></table>
            </div>
        </div>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        var editFlag = [[${@permission.hasPermi('paea:signature:edit')}]];
        var removeFlag = [[${@permission.hasPermi('paea:signature:remove')}]];
        var statusDatas = [[${@dict.getType('signature_status')}]];
        var prefix = ctx + "paea/signature";

        $(function() {
            var options = {
                url: prefix + "/querySingatures",
                modalName: "有权人签字",
                //启用跳转至指定页
                showPageGo: true,
                //启用点击选中行
                clickToSelect: true,
                onDblClickRow:_onDblClickRow,
                columns: [{
                    radio: true
                },
                {
                    field : 'id', 
                    title : '主键ID',
                    visible: false
                },
                {
                    field : 'orgCode', 
                    title : '机构号'
                },
                {
                    field : 'orgName', 
                    title : '机构名称'
                },
                {
                    field : 'position', 
                    title : '授权人职位'
                },
                {
                    field : 'name', 
                    title : '授权人姓名'
                },
                {
                    field : 'status', 
                    title : '状态',
                    formatter: function(value, row, index) {
                       return $.table.selectDictLabel(statusDatas, value);
                    }
                },
                {
                    field : 'startDate', 
                    title : '影像启用日期'
                },
                {
                    field : 'endDate', 
                    title : '影像停用日期'
                },
                {
                    field : 'createBy',
                    title : '创建者'
                },
                {
                    field : 'createTime', 
                    title : '创建时间'
                },
                {
                    field : 'updateBy', 
                    title : '更新者'
                },
                {
                    field : 'updateTime', 
                    title : '更新时间'
                },
                {
                    field : 'remark',
                    title : '备注',
                    visible : false
                },
                {
                    title: '操作',
                    align: 'center',
                    formatter: function(value, row, index) {
                        var actions = [];
                        actions.push('<a class="btn btn-danger btn-xs" href="javascript:void(0)" onclick="viewDetail(\'' + row.id + '\')"><i class="fa fa-info"></i>查看详情</a>');
                        return actions.join('');
                    }
                }]
            };
            $.table.init(options);
        });
        function _onDblClickRow(row) {
            var url = prefix+"/view/"+row.id;
            //$.modal.openFull("查看详情", url);
            window.showModalDialog(url,"查看详情","dialogWidth=850px; dialogHeight=650px; help=no; status=no; scroll=yes; resizable=no;");
        }
        function viewDetail(id){
            var url = prefix+"/view/"+id;
            //$.modal.openFull("查看详情", url);
            window.showModalDialog(url,"查看详情","dialogWidth=850px; dialogHeight=650px; help=no; status=no; scroll=yes; resizable=no;");
        }
    </script>
</body>
</html>